public class Rectangle implements IShape {
    private Point ptTopLeft;
    private Point ptTopRight;
    private int width;
    private int height;

    public Rectangle() {
        this(new Point(), 0, 0);
    }

    public Rectangle(Point topLeft, int height, int width) {
        this.ptTopLeft = new Point(topLeft);
        this.ptTopRight = new Point(topLeft.x + width, topLeft.y);
        this.width = width;
        this.height = height;
    }

    @Override
    public double perimeter() {
        return 2 * (width + height);
    }

    @Override
    public double area() {
        return width * height;
    }

    @Override
    public void draw() {
        System.out.printf("Drawing Rectangle at (%d, %d) width=%d height=%d\n",
                ptTopLeft.x, ptTopLeft.y, width, height);
    }
}